function [ is_extract_data ] = IsExtracting( is_constant_speed,is_lateral )
% determine wether to extract data

 if (is_constant_speed == true)&&(is_lateral == false)
 % need to satisfy 2 conditons: constant speed and lateral motion           
            is_extract_data = true;
 else
            is_extract_data = false;
 end

end

